Remove parser module indirection used in testing#1699
Merged
kou merged 1 commit intoruby:masterfrom May 7, 2026
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR removes the extra indirection layer in the Ruby parser test suite by inlining the previously mixed-in test cases directly into the RDocParserRubyTest class, which should make it easier to run individual tests (e.g., via ruby-lsp).
Changes:
- Converted
test/rdoc/parser/ruby_test.rbfrom aRDocParserRubyTestCasesmixin module + including test class into a singleRDocParserRubyTestclass containing the test methods directly. - Updated
AGENTS.mdto describe where Ruby parser tests live (but the referenced class name currently doesn’t match the code).
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| test/rdoc/parser/ruby_test.rb | Removes the module/include indirection by placing all Ruby parser tests directly in RDocParserRubyTest. |
| AGENTS.md | Updates contributor documentation about the Ruby parser test location/structure. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
The ripper parser is gone, so this is not needed anymore Makes it so that I can easily run individual tests via ruby-lsp It's their limitation really but seems ok to do regardless
abc4512 to
ec8ef12
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The ripper parser is gone, so this is not needed anymore
Makes it so that I can easily run individual tests via ruby-lsp It's their limitation really but seems ok to do regardless